package belf.migrate.engine.ddl;

import belf.migrate.api.model.QualifiersModel;
import belf.migrate.api.table.schema.TablePath;
import belf.migrate.api.util.FieldCase;
import belf.migrate.api.util.JdbcUrlUtil;
import belf.migrate.api.util.QualifiedType;
import belf.migrate.plugin.dameng.DamengCatalog;
import belf.migrate.plugin.mysql.MySQLCatalog;
import belf.migrate.plugin.sqlserver.SqlServerCatalog;

public class SqlServerDDLConvertTestBase {
    protected static String SCHEMA = "Person";
    protected static JdbcUrlUtil.UrlInfo urlInfo = new JdbcUrlUtil.UrlInfo(
            "jdbc:sqlserver://39.105.183.163:1433;databaseName=AdventureWorks2022;encrypt=true;trustServerCertificate=true",
            "jdbc:sqlserver://39.105.183.163:1433",
            "39.105.183.163",
            1433,
            SCHEMA,
            ""
    );
    protected static JdbcUrlUtil.UrlInfo dmUrlInfo = new JdbcUrlUtil.UrlInfo(
            "jdbc:dm://localhost:5236?schema=" + SCHEMA,
            "jdbc:dm://localhost:5236",
            "localhost",
            5236,
            SCHEMA,
            ""
    );

    protected QualifiersModel qualifiersModel = new QualifiersModel("\"","\"", FieldCase.ORIGINAL, QualifiedType.DOT);
    protected TablePath tablePath = TablePath.of(SCHEMA, null,"film_text", qualifiersModel);

    protected static SqlServerCatalog sourceCatalog = new SqlServerCatalog("sa", "Qwer1234", urlInfo, SCHEMA, false);

    protected static DamengCatalog sinkCatalog = new DamengCatalog("sysdba", "test12345", dmUrlInfo, SCHEMA, true);
}
